package com.wanmei.service;

import com.github.pagehelper.PageInfo;
import com.wanmei.exception.WanmeiException;
import com.wanmei.pojo.Category;
import com.wanmei.pojo.Product;
import com.wanmei.pojo.Productkuid;

import java.util.List;

public interface ProductService {

    PageInfo<Product> getProductByFuzzy(String likeValue,int pageNum,int pageSize);

    Product selectByPrimaryKey(Integer pid);//通过图片获取信息。

    public PageInfo<Object>  showProductDESC(int pageNum,int pageSize );

    PageInfo<Object> showProduct(int pageNum, int pageSize);

    PageInfo<Category> showProductCategory(int pageNum, int pageSize);

    int productAddService(Product product);
    int saveProductInfo(Product product, String realPath) throws WanmeiException;

    List<Product> selectProductInfoByPid(Integer pid);

    List<Productkuid> selectProductKuidByPid(Integer pid);

    List<Object> selectProductKuid();

    int updateProductInfo(Product product, String[] vids , String[] storenums,String realPath) throws WanmeiException;

    int deleteProductByPid(Integer pid);

    List<Product> findAll();

}
